package com.example.invoicingsystem.service.impl;
import com.example.invoicingsystem.mapper.UsersMapper;
import com.example.invoicingsystem.pojo.Users;
import com.example.invoicingsystem.service.UsersService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UsersServiceImpl implements UsersService {
	@Autowired
	private UsersMapper usersMapper;

	@Override
	public List<Users> selectAll() {
		return usersMapper.selectAll();
	}
	public List<Users> select(Users user) {
		return usersMapper.select(user);
	}
	public int insert(Users user) {
		return usersMapper.insert(user);
	}
	public int update(Users user) {
		return usersMapper.updateByPrimaryKey(user);
	}
	public int delete(Users user) {
		return usersMapper.deleteByPrimaryKey(user);
	}

}
